﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using NUnit.Framework;

namespace NUnitTestProjectPlayground.BlackSwap
{
    [TestFixture]
    class TestThrow
    {

        int _orderValue;

        [SetUp]
        public void SetUp()
        {
            _orderValue = 100;
        }

        public static void Calculate ()
        {
            int b = 0;
            int c = 5/b;
        }


        [Test]
        [ExpectedException(typeof(DivideByZeroException))]
        public void Trowable()
        {
            TestDelegate del = new TestDelegate(Calculate);
            del();
            //Assert.Throws(typeof (int), del);
        }
    }
}
